<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Title</title>
</head>
<body>

</body>
<script>
  //1.只声明不赋值 =>undefined
  var a;
  console.log(a);
  //2.不赋值不声明 报错
  console.log(b);
  //3.只赋值不声明  =>10（不推荐）
  c = 10;
  console.log(c);
</script>
</html>